package enums;

public enum  ExceptionEnum {

    PRICE_CANNOT_BE_NULL(1,"价格不能为空"),
    CATEGORY_NOT_FOUND(404,"商品分类没有查到"),
    BRAND_NOT_FOUND(500,"品牌没有查询到"),
    BRAND_SAVE_ERROR(500,"新增品牌失败"),
    UPLOAD_FILE_ERROR(500,"文件上传失败"),
    INVALID_FILE_TYPE(400,"无效的文件类型"),
    SPEC_GROUP_NOT_FOUND(400,"类别组没有找到"),
    SPEC_PARAM_NOT_FOUND(400,"商品规格参数不存在"),
    GOODS_NOT_FOUND(400,"商品没有查询到"),
    GOODS_DETAIL_NOT_FOUND(400,"商品详情没有查询到"),
    GOODS_SAVE_ERROR(400,"新增商品失败"),
    GOODS_SKU_NOT_FOUND(400,"商品sku不存在"),
    ;
    private  int code;
    private  String msg;
    public int getCode() {
        return code;
    }
    public void setCode(int code) {
        this.code = code;
    }
    public String getMsg() {
        return msg;
    }
    public void setMsg(String msg) {
        this.msg = msg;
    }

    ExceptionEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }
}
